

package com.maoshi.shop.distribution.comment.dao;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.maoshi.shop.distribution.comment.model.DistributionProd;
import com.maoshi.shop.distribution.comment.po.DistributionProdPO;
import org.apache.ibatis.annotations.Param;

public interface DistributionProdMapper extends BaseMapper<DistributionProd> {

    IPage<DistributionProd> distributionProdsPage(Page page, @Param("distributionProd") DistributionProd distributionProd, @Param("prodName") String prodName);

    IPage<DistributionProdPO> distributionProdPOPage(Page page, @Param("prodName") String prodName, @Param("sort") Integer sort, @Param("orderBy") Integer orderBy);

    DistributionProdPO getDistributionProdPOByProdId(@Param("prodId") Long prodId);

    int updateState(@Param("distributionProdId") Long distributionProdId, @Param("state") int state);
}
